<?php

class PublicController extends Controller {

    public $Module = 'api';
    public $Controller = 'public';
    public $Action = 'index';
    public $UserConfig = array();

    public function IndexAction() {
        // 赋值
        $this->Config = Config::GetConfig();
        $this->Assign('Config', $this->Config);
        $this->UserConfig = Cookie::GetMember('api');
        $this->Assign('UserConfig', $this->UserConfig);
        
        $this->LoadHelper($this->Module. '/' .$this->Controller.'_'.$this->Action);
    }
    
    public function BankAction() {
        // 赋值
        $this->Config = Config::GetConfig();
        $this->Assign('Config', $this->Config);
        $this->UserConfig = Cookie::GetMember('api');
        $this->Assign('UserConfig', $this->UserConfig);
        
        $this->LoadHelper($this->Module. '/' .$this->Controller.'_'.$this->Action);
    }
    
    public function DealersAction() {
        // 赋值
        $this->Config = Config::GetConfig();
        $this->Assign('Config', $this->Config);
        $this->UserConfig = Cookie::GetMember('api');
        $this->Assign('UserConfig', $this->UserConfig);
        
        $this->LoadHelper($this->Module. '/' .$this->Controller.'_'.$this->Action);
    }
    
    public function MemberAction(){
        // 赋值
        $this->Config = Config::GetConfig();
        $this->Assign('Config', $this->Config);
        $this->UserConfig = Cookie::GetMember('api');
        $this->Assign('UserConfig', $this->UserConfig);
        
        $this->LoadHelper($this->Module. '/' .$this->Controller.'_'.$this->Action);
    }
    
    public function PushtestAction(){
        $this->LoadResurces('push/class.umeng');
        $umeng = new Umeng();
        //ANDROID
        $result = $umeng->androidSend(array(
            'type' => 'customizedcast',
            'alias_type' => 'user',
            'alias' => 1,
            'display_type' => 'notification',
            'ticker' => '通知表示',
            'title' => '标题',
            'text' => '立刻问问'
        ));
        echo $result;
    }

}